package com.dxy.app.act_widget.adapter;

import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentPagerAdapter;
import android.view.View;
import java.util.List;

/**
 * Created by dell on 2017/8/8.
 */

public class StatusBarAdapter extends FragmentPagerAdapter {

  private List<Fragment> list;

  public StatusBarAdapter(FragmentManager fm) {
    super(fm);
  }
  public StatusBarAdapter(FragmentManager fm,List<Fragment> list){
    super(fm);
    this.list =list;
  }

  @Override public int getCount() {
    return list.size();
  }

  @Override public boolean isViewFromObject(View view, Object object) {
    return view==object;
  }

  @Override public Fragment getItem(int position) {
    return list.get(position);
  }

}
